package cheme.Interpreter.AST.Interfaces;

import cheme.Interpreter.AST.Variable.AstVariable;

public interface IAstVariable extends IAstExpression, ISubject, IObserver
{
	public static final IAstVariable uninitialized = 
		new AstVariable(
				IAstIdentifier.uninitialized, 
				IAstExpression.uninitialized);
	
	public enum DeclarationState {InferredDeclaration, ExplicitDeclaration};
	
	IAstIdentifier getIdentifier();
	void setIdentifier(IAstIdentifier identifier);
		
	IAstExpression getExpression();
	void setExpression(IAstExpression expression);

	DeclarationState getDeclarationState();
	void setDeclarationState(DeclarationState state);

	void setValue(Double value);
	void setValueKeepingType(Double value);
}